-
Couldn't load subscription status.
- Fork 2.2k
feat: npm publish anvil, cast and chisel #11945
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
3e39c31 to
143d674
Compare
|
This feature would be very useful to us at |
|
yes, we could include. Btw forge is already published in npm so you could give ot a try already, this PR tracks publish of the other Foundry artifacts |
a47caf4 to
a19c5ef
Compare
6c57146 to
cd45f3a
Compare
733fb07 to
9273fd8
Compare
|
looking for additional approval as I opened the ticket on behalf of @o-az successful run https://github.com/foundry-rs/foundry/actions/runs/18871258811/job/53850363401 CC @DaniPopes @0xrusowsky @zerosnacks @onbjerg |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i'm not an expert, but i think it looks good.
left some minor cmnts though
| # Anvil | ||
|
|
||
| Anvil is a fast local Ethereum development node. | ||
| The cast binary can be used both within and outside of a Foundry project. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| The cast binary can be used both within and outside of a Foundry project. | |
| The anvil binary can be used both within and outside of a Foundry project. |
| /** | ||
| * @typedef {'amd64' | 'arm64'} Arch | ||
| * @typedef {'linux' | 'darwin' | 'win32'} Platform | ||
| * @typedef {'forge' | 'cast' | 'anvil' | 'chisel'} Tool | ||
| * @typedef {'debug' | 'release' | 'maxperf'} Profile | ||
| */ | ||
|
|
||
| /** @type {readonly Tool[]} */ | ||
| export const KNOWN_TOOLS = Object.freeze(['forge', 'cast', 'anvil', 'chisel']) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
imo it would be nice to centralize all supported platforms in a const with something like:
export const SUPPORTED_PLATFORMS = Object.freeze([
{ platform: 'darwin', arch: 'arm64' },
{ platform: 'darwin', arch: 'amd64' },
{ platform: 'linux', arch: 'arm64' },
{ platform: 'linux', arch: 'amd64' },
{ platform: 'win32', arch: 'amd64' },
])then we could easily add platform validation helpers:
export function isPlatformSupported(platform, arch)and dynamically generate the CI matrix, ensuring that it is in sync with the supported platforms (rather than manually declaring the huge matrix as we currently do)
Motivation
Solution
PR Checklist